package com.pet.system.service;

import com.auth0.jwt.interfaces.DecodedJWT;
import com.pet.system.entity.LoginUser;
import com.pet.system.entity.User;

import java.util.Map;

public interface TokenService {
    Map<String, Long> getLoginCacheMap();

    Long getLoginCacheToken(String token) throws Exception;

    String setLoginCacheToken(String token);

    void deleteLoginCacheToken(String token);

    String getToken(Map<String, String> map, Integer expires) throws Exception;

    DecodedJWT verify(String token) throws Exception;

    String login(LoginUser loginUser) throws Exception;

    User getUser(String token) throws Exception;
}
